<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%
	String path = request.getContextPath();
%>
<%@ taglib uri="/WEB-INF/tld/c.tld" prefix="c"%>
<%@ taglib uri="/WEB-INF/tld/ui.tld" prefix="ui"%>
<!DOCTYPE html>
<html lang="zh-CN">
<head>
<c:set var="ctx" value="${pageContext.request.contextPath}" />
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>供应商配置维护</title>
<jsp:include page="../../import.jsp" flush="true" />
</head>
<body class="iframeBody">
	<div class="Wrapper">
		<div id="pageInTab" class="pageInTab">
			<form id="formSet1">
				<div class="sqPanel">
					<div class="sqPanel_head inL">
						<span>管理员信息</span>
					</div>
					<div class="sqPanel_body">
						<div id="ligergrid_A1" class="sq-grid"></div>
					</div>
				</div>
			</form>
		</div>
	</div>

<script type="text/javascript">
var npSocialRlGrid=null,splId='${splId}',splBizTypCdList =${splBizTypCdList};
$(function(){
	$('#formSet1').ligerForm({
        validate : true
	});
	initSplConfigGrid();
});

        //初始化管理人员信息
        function initSplConfigGrid() {
        	if(!splId){//供应商ID为空  新增供应商
                return;
        	}
        	npSocialRlGrid = $("#ligergrid_A1").ligerGrid({
                url: '<%=path%>/product/splUsrR/searchSplCofigInfo.do?',
				method : 'get',
				parms : {
					splId : splId
				},
				async : false,
				columns : [ {
					display : '业务类型',
					name : 'splBizTypCdNm',
					editor : {
						type : 'String'
					}
				}, {
					display : '事业部',
					name : 'orgDispNm',
					editor : {
						type : 'String'
					}
				}, {
					display : '管理员',
					name : 'rlNm',
					editor : {
						type : 'String'
					}
				}, {
					display : '联系方式',
					name : 'mp',
					editor : {
						type : 'String'
					}
				} ],
				pageSize:10,
		        root:'rows',
		        record:'total',
		        hideLoadButton : true,
		        width: '100%',
		        height : 300,
				heightDiff : -2,
				enabledEdit : true,
		        isScroll: false,
		        checkbox:false,
		        rownumbers:true,
		        allowUnSelectRow : true,
				alternatingRow : false,
				enabledSort : false,
				onAfterShowData : function() {
					SetIframe_height();
				},
		        onRenderComplete: function () {
		        	iframeResize ();
		        },
		        onSelectRow: function (rowdata, rowid, rowobj) {
		        	isEditable(rowdata.refIsSysDef);
		        },
		        onSuccess: function (data, grid) {
		        }
			});
		};
		
		function iframeResize () {
		    if (parent.parent.mainApp) {
		        parent.parent.mainApp.parentTab.onResize();
		    };
		};
		
		/*
		是否系统内置参数获取
		*/
		function isEditable(isSysDef){
			if(isSysDef==1){
				Editable=false;
			}else{
				Editable=true;
			}
		};
	</script>
</body>
</html>
